<div class="form-content">
  <form nz-form [formGroup]="briefForm" >
    <nz-form-item>
      <nz-form-label  nzRequired nzFor="suject">主题</nz-form-label>
      <nz-form-control  [nzErrorTip]="subjectErrorTpl" >
        <input nz-input formControlName="subject" id="subject" placeholder="输入小于10字的主题"/>
        <ng-template #subjectErrorTpl let-control>
          <ng-container *ngIf="control.hasError('required')">
            请输入主题内容!
          </ng-container>
          <ng-container *ngIf="control.hasError('maxlength')">
            输入内容应少于10字!
          </ng-container>
        </ng-template>
      </nz-form-control>
    </nz-form-item>
    <nz-form-item>
      <nz-form-label  nzRequired nzFor="brief">简报</nz-form-label>
      <nz-form-control [nzErrorTip]="briefErrorTpl">
        <nz-textarea-count [nzMaxCharacterCount]="100">
          <textarea nz-input formControlName="brief" id="brief" rows="6" > </textarea>
        </nz-textarea-count>
        <ng-template #briefErrorTpl let-control>
          <ng-container *ngIf="control.hasError('required')">
            请输入简报内容!
          </ng-container>
          <ng-container *ngIf="control.hasError('maxlength')">
            输入内容应少于100!
          </ng-container>
        </ng-template>
      </nz-form-control>
    </nz-form-item>
  </form>
</div>
